<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <link rel="stylesheet" href="css/header.css">
    <link href="css/carousel.css" rel="stylesheet">
    <link rel="stylesheet" href="css/uindex.css">
    <link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
    <script src="js/carousel.js"></script>
    <script src="js/vue.min.js"></script>
    <script src="https://unpkg.com/element-ui/lib/index.js"></script>
</head>
<style>
    .el-carousel__item h3 {
        color: #475669;
        font-size: 14px;
        opacity: 0.75;
        line-height: 200px;
        margin: 0;
    }

    .el-carousel__item:nth-child(2n) {
        background-color: #99a9bf;
    }

    .el-carousel__item:nth-child(2n+1) {
        background-color: #d3dce6;
    }
</style>

<body>
    <div class="app">
        <header>
            <div class="projectName">汽车轴承寿命预测平台</div>
            <el-input placeholder="搜索" clearable style="width: 10vw;margin: 10px"></el-input>
            <el-menu :default-active="activeIndex" class="el-menu-demo" mode="horizontal" @select="handleSelect">
                <el-menu-item index="1" onclick=""><a href="uindex.jsp">首页</a></el-menu-item>
                <el-menu-item index="2"><a href="ShoppingServlet">商城</a></el-menu-item>
                <el-menu-item index="3"><a href="OrderListServlet">购物车</a></el-menu-item>
                <el-menu-item index="4"><a href="mine.jsp" target="_blank">我的</a></el-menu-item>
            </el-menu>
        </header>
        <div class="line"></div>
        <div class="lunbo">
            <el-carousel :interval="4000" type="card" height="400px">
                <el-carousel-item v-for="item in imgList" :key="item">
                    <img :src="item" alt="" style="width: 594px;height: 400px">
                </el-carousel-item>
            </el-carousel>
        </div>
        <div>

        </div>
    </div>
</body>
<script>
    new Vue({
        el: '.app',
        data() {
            return {
                imgList: [
                    "./img/zhou1.jpg",
                    "./img/zhou2.gif",
                    "./img/zhou3.jpg"
                ], activeIndex: '1',
                activeIndex2: '1'
            }
        }, methods: {
            handleSelect(key, keyPath) {
                console.log(key, keyPath);
            }
        }
    })
</script>
</html>